import request from '@/utils/request'

// 查询订单收益提现列表
export function listWithdrawal(query) {
  return request({
    url: '/suppliers/withdrawal/list',
    method: 'get',
    params: query
  })
}

// 查询订单收益提现详细
export function getWithdrawal(id) {
  return request({
    url: '/suppliers/withdrawal/' + id,
    method: 'get'
  })
}

// 新增订单收益提现
export function addWithdrawal(data) {
  return request({
    url: '/suppliers/withdrawal',
    method: 'post',
    data: data
  })
}

// 修改订单收益提现
export function updateWithdrawal(data) {
  return request({
    url: '/suppliers/withdrawal',
    method: 'put',
    data: data
  })
}

// 删除订单收益提现
export function delWithdrawal(id) {
  return request({
    url: '/suppliers/withdrawal/' + id,
    method: 'delete'
  })
}

// 导出订单收益提现
export function exportWithdrawal(query) {
  return request({
    url: '/suppliers/withdrawal/export',
    method: 'get',
    params: query
  })
}

// 获取提现记录关联订单列表
export function getOrderByWithdid(id) {
  return request({
    url: '/suppliers/withdrawal/getOrderByWithdid/'+id,
    method: 'get'
  })
}

// 获取提现记录关联订单列表
export function plUpdateState(data) {
  return request({
    url: '/suppliers/withdrawal/plUpdateState/'+data.withdState+"/"+data.ids,
    method: 'post'
  })
}


export function shopSyTj(data) {
  return request({
    url: '/suppliers/withdrawal/shopSyTj/'+data.supplierId,
    method: 'get'
  })
}

